#define DEBUG
#include <cstdio>

using namespace std;

const int maxm=30000;

int main() {
#ifdef DEBUG
  freopen("1.in", "r", stdin);
  freopen("1.out", "w", stdout);
#endif

  static int side[maxm][2];
  int n, m;
  scanf("%d %d", &n, &m);
  for (int i=1; i<=m; i++) {
    scanf("%d %d", side[i], side[i]+1);
  }

  int ans=0;
  for (int i=0; i<(1<<n); i++) {
    bool flag=true;
    for (int j=1; j<=m && flag; j++) {
      flag = !(((i>>(side[j][0]-1))&1) && ((i>>(side[j][1]-1))&1));
    }
    if (flag) {
      int t=0;
      for (int j=0; j<n; j++) {
	t += (i>>j)&1;
      }
      ans = ans>t ? ans : t;
    }
  }

  printf("%d", ans);

  fclose(stdin);
  fclose(stdout);
  return 0;
}
